package com.zhongke.cotrun.service;

import com.github.pagehelper.PageInfo;
import com.zhongke.cotrun.model.pojo.InnovationActivitiesEntity;
import com.zhongke.cotrun.model.pojo.InnovationActivitiesEntityVo;

import java.util.Map;


/**
 * 创新活动表
 *
 * @author lee
 * @email wawzj512541@gmail.com
 * @date 2019-11-15 14:59:00
 */
public interface InnovationActivitiesService {

    /**
     * 分页查询显示
     *
     * @return
     */
    public PageInfo showByPage(InnovationActivitiesEntityVo innovationActivitiesEntity, Integer pageNum, Integer pageSize);
    //管理员
    PageInfo showByPageForManager(InnovationActivitiesEntityVo innovationActivitiesEntity, Integer pageNum, Integer pageSize);
    /**
     * 根据id查找
     *
     * @param id
     * @return
     */
    public InnovationActivitiesEntityVo selectByID(Integer id);

    /**
     * 新增
     *
     * @param innovationActivitiesEntity
     * @return
     */
    public boolean addInnovationActivities(InnovationActivitiesEntity innovationActivitiesEntity);

    /**
     * 根据id逻辑删除
     *
     * @param id
     * @return
     */
    public boolean deleteByID(Integer id);

    /**
     * 批量删除
     *
     * @param ids
     * @return
     */
    public boolean deleteBatch(String ids);

    /**
     * 更新
     *
     * @param innovationActivitiesEntity
     * @return
     */
    public boolean updateByID(InnovationActivitiesEntity innovationActivitiesEntity);

    /**
     * 修改状态
     *
     * @param id
     * @param status
     * @return
     */
    public boolean updateStatus(Integer id, Integer status);

    /**
     * 定时结束活动
     * @return
     */
    int cronJobsUpdateState2();
    /**
     * 根据id查询当前活动能否报名
     *
     * @param id
     * @return
     */
    public boolean enbaleRegistration(Integer id);

    Map<String, Object> activitiesRiseTrend(String dateType, Integer size);

    boolean updateStatus(Integer id, Integer status, String reason);

    boolean updateDemandsApprovalStatus(int approvalStatus, String s, Integer id);

    PageInfo showByPageForCenter(InnovationActivitiesEntityVo innovationActivitiesEntity, Integer pageNum, Integer pageSize);

    InnovationActivitiesEntityVo getSignUpInfo(Integer id);

    boolean closeActivities(Integer id);

	boolean updateApprovalStatusAndMall(int approvalStatus, String s, Integer id);

	int queryUnApprovalCounts();

    PageInfo queryOrderForCenter(InnovationActivitiesEntityVo innovationActivitiesEntity, Integer pageNum, Integer pageSize);
}

